package com.woniuxy.factory.mapper;

import com.woniuxy.factory.entity.Purchasegoods;
import com.woniuxy.factory.entity.Purchaseplan;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface PurchasegoodsMapper {
    List<Purchasegoods> selectPurchasegoods(@Param("purchaseplan") Purchaseplan purchaseplan, @Param("home") int home, @Param("limit") int limit);

    int getCount(@Param("purchaseplan")Purchaseplan purchaseplan);

    int insertPurchaseGoods(@Param("pupId") String pupId, @Param("matId") String matId, @Param("quantity") int quantity);

    int deletepurchaseplangoods(int[] pugIds);

    /*根据采购计划编号查询所有的采购项，仓库调用*/
    List<Purchasegoods> selectPurchasegoodsByPupId(String pupId);
}
